<div class="editoras index">
	<h2><?php echo __('Editoras');?></h2>
	
	<div class="actions">
		<?php echo $this->Html->link('Nova', '/editoras/novo');?>
	</div>
	
	<div class=pagging>
		<p>
		<?php
		echo $this->Paginator->counter(array(
		'format' => __('Página {:page} de {:pages}, mostrando {:current} registros de um total de {:count}')
		));
		?>
		</p>
	</div>
	<table cellpadding="0" cellspacing="0">
	<tr>
			<th width="10px"><?php echo $this->Paginator->sort('Código');?></th>
			<th><?php echo $this->Paginator->sort('nome');?></th>
			<th class="actions"><?php echo __('Opções');?></th>
	</tr>
	<?php
	$i = 0;
	foreach ($editoras as $editora): ?>
	<?php if($i%2==0)$class="even";else $class='odd'?>
	<tr class="<?php echo $class;?>">
		<td><?php echo h($editora['Editora']['id']); ?>&nbsp;</td>
		<td><?php echo h($editora['Editora']['nome']); ?>&nbsp;</td>
		<td>
			<?php echo $this->Html->image(
									"actions/books.png", array(
										'url'=>array( 'action' => 'info', $editora['Editora']['id']),
										'alt'=>__('Lista de livros'),
										'title'=>__('Lista de livros')
									)
								); ?>
			<?php echo $this->Html->image(
									"actions/edit.png", array(
										'url'=>array('action' => 'editar', $editora['Editora']['id']),
										'alt'=>__("Editar"),
										'title'=>__("Editar"),
									)); ?>
			<?php echo $this->Form->postLink($this->Html->image(
									"actions/delete.png", array(
										'alt'=>__("Apagar"),
										'title'=>__("Apagar"),
									)),
									array('action' => 'apagar', $editora['Editora']['id']),
									array('escape'=>false),
									__('Deseja excluir %s?', $editora['Editora']['nome']));
									?>
		</td>
	</tr>
<?php $i++;endforeach; ?>
	</table>

	<div class="pagging">
		<div>
		<?php
			echo $this->Paginator->prev('< ' . __('Anterior'), array(), null, array('class' => 'prev disabled'));
			echo $this->Paginator->numbers(array('separator' => ''));
			echo $this->Paginator->next(__('Próximo') . ' >', array(), null, array('class' => 'next disabled'));
		?>
		</div>
	</div>
</div>